﻿var systemManageStore = Ext.create('Roy.store.main.SystemManage');
var logManageStore = Ext.create('Roy.store.main.LogManage');

Ext.define('Roy.view.main.Menu', {
    extend: 'Ext.panel.Panel',
    alias: 'widget.main_menu',

    //requires: ['Roy.view.main.FunctionTree'],

    initComponent: function () {
        var me = this;
        Ext.apply(this, {
            title: '功能导航',
            collapsible: true,
            split: true,
            width: 210,
            layout: 'accordion',
            items: []
        });

        me.items.push(Ext.create('Roy.view.main.SystemManage',
         {
             id: 'systemManage',
             title: '系统管理',
             width: 210,
             height: 150,
             store: systemManageStore,
             rootVisible: false,
             renderTo: document.bodys
         })
        );

        me.items.push(Ext.create('Roy.view.main.LogManage',
        {
            id: 'logManage',
            title: '日志管理',
            width: 210,
            height: 150,
            store: logManageStore,
            rootVisible: false,
            renderTo: document.bodys
        })
       );

        me.callParent(arguments);
    }
});